//
//  RORegisterViewController.swift
//  健身宝
//
//  Created by hzt on 2017/9/26.
//  Copyright © 2017年 hzt. All rights reserved.
//

import UIKit

class RORegisterViewController: UIViewController {
    
    @IBOutlet weak var Tel: UITextField!
    @IBOutlet weak var Pwd: UITextField!
    @IBAction func RegBtn(_ sender: UIButton) {
        if Tel.text == "" {
                
            //print("密码没有输入")
                MBProgressHUD.showDelayHUDToView(self.view, message:"手机号码没有输入")
            }else{
                
                if Pwd.text == "" {
                    
                    
                    MBProgressHUD.showDelayHUDToView(self.view, message:"密码没有输入")
                }else{
                    let parameters:NSDictionary = ["tel":self.Tel.text!,"password":self.Pwd.text!] as NSDictionary
                            
                            RONetworkMngTool.shareNetworkMngTool().RONetwork_Register(parameters, view: self.view, block: { (flag) in
                                if flag == "1" {
                                    print("注册成功 跳转到主页")
                                    
                                }else{
                                    print("注册失败")
                                    
                                }
                            })
                        }
                    }
        
    
    
    

}
}
